﻿using System;
using System.Collections.Generic;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Windows;

namespace NavigationDemo
{
    /// <summary>
    /// Interaction logic for App.xaml
    /// </summary>
    public partial class App : Application
    {
        private static MainController controller;

        public static MainController Controller
        {
            get
            {
                if (controller == null)
                {
                    controller = new MainController();
                }
                return controller;
            }
        }

        protected override void OnActivated(EventArgs e)
        {
            this.MainWindow.DataContext = Controller;
        }
    }
}
